@extends('admin.common.app')
@section('cont')
    <section class="Hui-article-box">
        <nav class="breadcrumb"><i class="Hui-iconfont">&#xe67f;</i> 首页
            <span class="c-gray en">&gt;</span>管理员
            <span class="c-gray en">&gt;</span>分配权限
            <a class="btn btn-success radius r" style="line-height:1.6em;margin-top:3px"
               href="javascript:location.replace(location.href);" title="刷新">
                <i class="Hui-iconfont">&#xe68f;</i>
            </a>
        </nav>
        <article class="cl pd-20">
            @include('admin.common.msg')
            <form action="{{ route('admin.admin.role',$admin) }}" method="post" class="form form-horizontal">
                @csrf
                <div class="row cl">
                    <label class="form-label col-xs-4 col-sm-3">
                        用户名称：
                    </label>
                    <div class="formControls col-xs-8 col-sm-9">
                       {{$admin->username}}
                    </div>
                </div>
                <div class="row cl">
                    <label class="form-label col-xs-4 col-sm-3">
                        姓名：
                    </label>
                    <div class="formControls col-xs-8 col-sm-9">
                        {{$admin->truename}}
                    </div>
                </div>
                <div class="row cl">
                    <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>权限列表</label>
                    <div class="formControls col-xs-8 col-sm-9 skin-minimal">
                        @foreach($roleAll as $itme)

                        <div class="radio-box">
                            <input type="radio" value="{{$itme->id}}" name="roles_id"
                            @if($itme->id==$admin->roles_id) checked @endif>
                            <label for="sex-1" style="font-size:17px;background-color: #fffdef ">
                                {{$itme->name}}
                            </label>
                        </div>
                        @endforeach
                    </div>
                </div>
                <div class="row cl">
                    <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                        <input class="btn btn-primary radius" type="submit" value="分配权限">
                    </div>
                </div>
            </form>
        </article>
    </section>
@endsection
@section('js')

@endsection
